import request from '@/utils/request'

/**
 * 小区数据
 */
export function BBSDataAPI(data) {
  return request({
    method: 'get',
    url: '/community',
    params: data
  })
}
/**
 * 小区数据
 */
export function DelBBSDataAPI(id) {
  return request({
    method: 'DELETE',
    url: `/community/${id}`
  })
}

/**
 * 数据上传community
 */
export function dataUploadAPI(data) {
  return request({
    method: 'POST',
    url: `/community`,
    data: data
  })
}

/**
 * 获取单个小区详情
 */
export function singleParticulars(id) {
  return request({
    method: 'get',
    url: `/community/${id}`
  })
}

/**
 * 获取单个小区详情
 */
export function compileParticularsAPI(data) {
  return request({
    method: 'PUT',
    url: `community/${data.id}`,
    data: data
  })
}
